package com.kehutong.wxapi.response;

import org.coraframework.json.JSON;
import org.coraframework.json.JSONObject;
import org.coraframework.json.annotation.JSONField;

import java.util.List;

/**
 * @author: liukunlong
 * @date: 2021-03-04 16:51
 */
public class ExternalContactListResponse {
    public static void main(String[] args) {
       String str="{\n" +
               "\"errcode\": 0,\n" +
               "\"errmsg\": \"ok\",\n" +
               "\"external_userid\":[\"woAJ2GCAAAXtWyujaWJHDDGi0mACAAA\",\"wmqfasd1e1927831291723123109rAAA\"]\n" +
               "}";
        final JSONObject rs = JSON.parseObject(str);
        ExternalContactListResponse pp = JSON.parseObject(str, ExternalContactListResponse.class);
        System.out.println(pp.getExternalUseridList().toString());
        System.out.println(rs.toJSONString());
    }
    @JSONField(name = "errcode")
    private Integer errcode;
    /**
     * errmsg
     */
    @JSONField(name = "errmsg")
    private String errmsg;
    /**
     * externalContactList
     */
    @JSONField(name = "external_userid")
    private List<String> externalUseridList;

    public Integer getErrcode() {
        return errcode;
    }

    public void setErrcode(Integer errcode) {
        this.errcode = errcode;
    }

    public String getErrmsg() {
        return errmsg;
    }

    public void setErrmsg(String errmsg) {
        this.errmsg = errmsg;
    }

    public List<String> getExternalUseridList() {
        return externalUseridList;
    }

    public void setExternalUseridList(List<String> externalUseridList) {
        this.externalUseridList = externalUseridList;
    }
}
